
<div id="main">
	<ol class="breadcrumb">
		<li><a href="{:U('Index/main')}"><span class="glyphicon glyphicon-home"></span></a></li>{$breadcrumb}
	</ol>
	<div class="row">
		<div class="col-md-12">
			<div class="panel panel-default">
				<div class="panel-heading">{$other_action}</div>
				<form>
					<div class="panel-body">
						<div class="table-responsive">
							<table class="table table-striped table-bordered table-hover">
								<thead>
									<tr>
										<th width="40">排序</th>
										<th>ID</th>
										<th>栏目名称</th>
										<th>栏目类型</th>
										<th>所属模型</th>
										<th>是否显示</th>
										<th width="15%">操作</th>
									</tr>
								</thead>
								<tbody>
									{$list}
								</tbody>
							</table>
						</div>
					</div>
					<div class="panel-heading">
						<a href="" class="btn btn-primary btn-xs ajax-post" data-url="{:U('')}" data-location="reload" data-modal="false">排序</a>
					</div>

				</form>
			</div>
		</div>
	</div>
</div>
<script>
	$(function(){
		$('td.is_show').each(function(i, v){
			if(parseInt($.trim($(v).attr('data-is-show'))) == 1){
				$(v).html('<a class="ajax-get" data-url="{:U(\'\', array(\'type\' => \'change_is_show\'))}?id=' + $(v).attr('data-id') + '" data-location="reload" href="">显示</a>');
			}else{
				$(v).html('<a class="ajax-get" data-url="{:U(\'\', array(\'type\' => \'change_is_show\'))}?id=' + $(v).attr('data-id') + '" data-location="reload" href="" style="color: #ccc;">隐藏</a>');
			}
		});
	});
</script>
